#include "Generate_C_std.h"

class Pattern_label : public Pattern
{
public:
	bool match(Statement* that)
	{
		use_scope = false;
		label = new Wildcard<LABEL_NAME>;
		return that->match(new Label(label));
	}

	void generate_code(Generate_C* gen)
	{
		buf << *label->value->value << ":;\n";
	}

protected:
	Wildcard<LABEL_NAME>* label;
};

CREATE(Pattern_label);
